from .load_env import *

models = ["models.users"]
TORTOISE_ORM = {
    'connections': {
        'default': {
            'engine': 'tortoise.backends.mysql',
            'credentials': {
                'host': DB_HOST,
                'user': DB_USER,
                'password': DB_PASSWORD,
                'port': DB_PORT,
                'database': DB_DATABASE,
            }
        },
    },
    'apps': {
        'models': {
            'models': ["aerich.models", *models],
            'default_connection': 'default',
        },

    }

}

# 数据库迁移 https://blog.csdn.net/weixin_54217348/article/details/136772215
